{extend name="template/base" /}
{block name="style"}
<style>
    .current a{
        color:#fff;
    }
    .tabBar a:hover{
        text-decoration: none;
    }
</style>
{/block}
{block name="content"}
<div class="page-container">
    <div id="tab_upload" class="HuiTab">
        <div class="tabBar cl mb-20">
            {switch name="$Request.param.cid"}
                {case value="1"}
                <span class="current"><a href="{:url('index',['cid'=>1])}">劳务公司</a></span>
                <span><a href="{:url('index',['cid'=>2])}">劳务分组</a></span>
                <span><a href="{:url('index',['cid'=>4])}">专业分包</a></span>
                {/case}
                {case value="2"}
                <span><a href="{:url('index',['cid'=>1])}">劳务公司</a></span>
                <span  class="current"><a href="{:url('index',['cid'=>2])}">劳务分组</a></span>
                <span><a href="{:url('index',['cid'=>4])}">专业分包</a></span>
                {/case}
                {case value="4"}
                <span><a href="{:url('index',['cid'=>1])}">劳务公司</a></span>
                <span><a href="{:url('index',['cid'=>2])}">劳务分组</a></span>
                <span  class="current"><a href="{:url('index',['cid'=>4])}">专业分包</a></span>
                {/case}
                {default /}
                 <span class="current"><a href="{:url('index',['cid'=>1])}">劳务公司</a></span>
                 <span><a href="{:url('index',['cid'=>2])}">劳务分组</a></span>
                 <span><a href="{:url('index',['cid'=>4])}">专业分包</a></span>
            {/switch}
            
        </div>
        {include file="form" /}
        <div class="cl pd-5 bg-1 bk-gray">
            <span class="l">
                <a class="btn btn-primary radius mr-5" href="javascript:;" onclick="layer_open('添加','/admin/brand/add/cid/{$Request.param.cid??\'1\'}.html')"><i class="Hui-iconfont">&#xe600;</i> 添加</a>
                {tp:menu menu="deleteforever" /}
                <a class="btn btn-primary radius mr-5" href="javascript:;" onclick="layer_open('分类管理','/admin/brand/manger/cid/{$Request.param.cid??\'1\'}.html')">分类管理 </a>
            </span>
            <span class="r pt-5 pr-5">
                共有数据 ：<strong>{$count ?? '0'}</strong> 条
            </span>

        </div>
        <div class="">
            <table class="table table-border table-bordered table-hover table-bg mt-20">
                <thead>
                <tr class="text-c">
                    <th width="25"><input type="checkbox"></th>
                    <th width="">{:sort_by('编号','id')}</th>
                    <th width="">公司名称</th>
                    <th width="">所属分类</th>
                    <th width="">图片</th>
                    <th width="">评论</th>
                    <th width="">详细</th>
                    <th width="70">操作</th>
                </tr>
                </thead>
                <tbody>
                {volist name="list" id="vo"}
                <tr class="text-c">
                    <td><input type="checkbox" name="id[]" value="{$vo.id}"></td>
                    <td>{$vo.id}</td>
                    <td>{$vo.bname|high_light=$Request.param.bname}</td>
                    <td>{$vo.cname|high_light=$Request.param.cname}</td>
                    <td><a href="/uploads/company/{$vo.img}" data-lightbox="preview"><img src="/uploads/company/{$vo.img}" width="150" height="75" alt=""></a></td>
                    <td>{$vo.comment|high_light=$Request.param.comment??'暂无'}</td>
                    <td>{$vo.content|htmlspecialchars_decode|high_light=$Request.param.content}</td>
                    
                    <td class="f-14">
                        <a title="编辑" href="javascript:;" onclick="layer_open('编辑','/admin/brand/edit/cid/{$Request.param.cid??\'1\'}/id/{$vo.id}.html')" style="text-decoration:none" class="ml-5"><i class="Hui-iconfont"></i></a>
                        {tp:menu menu='sdeleteforever' /}
                    </td>
                </tr>
                {/volist}
                </tbody>
            </table>
            <div class="page-bootstrap">{$page ?? ''}</div>
        </div>
    </div>
    
</div>
{/block}
{block name="script"}
<script type="text/javascript" src="__LIB__/lightbox2/js/lightbox.min.js"></script>
<script>
    // $.tpTab("#tab_upload .tabBar span", "#tab_upload .tabCon", "current", "click", "0", function (index, tabCon, tabBar) {
    //     if (index == 2 && tabCon.eq(index).find('.photo-list').html() == '') {
    //         getListImage({p:p,'count':'1'});
    //     }
    // }, function (i) {

    // });

</script>
{/block}

